import request from '@/utils/request'

//查询单期杂志内容列表
export function getSinglePeriodContents(params) {
    return request({
      url: '/api/readermagazinecontent/list',
      method: 'get',
      params
    })
  }
  //回显单篇文章内容
  export function getMagazineContentById(param) {
    return request({
      url: '/api/readermagazinecontent/update_view/'+param,
      method: 'get'
    })
  }

  //新增单期杂志文章
  export function insertMagazineContent(data) {
    return request({
      url: '/api/readermagazinecontent/insert',
      method: 'post',
      data: data
    })
  }
  //修改单期杂志单篇文章
  export function updateMagazineContent(data) {
    return request({
      url: '/api/readermagazinecontent/update',
      method: 'post',
      data: data
    })
  }

  //删除单期单篇杂志文章
  export function delMagazineContent(data) {
    return request({
      url: '/api/readermagazinecontent/delete',
      method: 'post',
      data: data
    })
  }
  //批量删除单期单篇杂志文章
  export function delMagazineContents(data) {
    return request({
      url: '/api/readermagazinecontent/deleteIds',
      method: 'post',
      data: data
    })
  }
  